<?php
/**
 * You can override all dkret3 helper functions (those wrapped in a function_exists() call)
 * by defining them first in this functions.php file.
 * Simply copy the desired function from 'dkret3/library/extensions/core.php' to this theme's
 * functions.php, so the child theme functions would be used.
 *
 * Or remove added functions by using remove_action() or remove_filter() and attach
 * your own function to the hook.
 *
 * For more information on hooks, see http://codex.wordpress.org/Plugin_API.
 *
 * Because entry-title, entry-meta-before, entry-meta, comment-meta informations use
 * easy to change shortcodes and are filtered, you can change them inside your child theme:
 *
 * <code>
 * add_filter( 'dkret_entry_title', 'my_dkret_entry_title' );
 * 
 * function my_dkret_entry_title() {
 *    return '[entry-title]';
 * }
 * </code>
 *
 * You can add html code and/or use some of the following shortcodes for your convenience:
 * [separator]
 * [entry-calendar], [entry-title], [entry-author], [entry-published]
 * [entry-categories], [entry-tags], [entry-comments], [entry-edit-link],
 * 
 * For comment-meta use the following shortcodes:
 * [comment-author], [comment-published], [comment-permalink],
 * [comment-reply-link], [comment-edit-link]
 * 
 * Have a look at dkret_title(), dkret_entry_meta_before(), dkret_entry_meta() and dkret_footer_text()
 * at the beginning of 'dkret3/library/functions/shortcode.php' to see the default settings.
 *
 * For further informations about Child Themes, see http://codex.wordpress.org/Child_Themes
 *
 * @package dkret3
 * @subpackage illumini
 * @since 3.6
 */


// child themes can unregister (and register) not used used sidebars
function illumini_remove_sidebars() {
    unregister_sidebar( 'primary-sidebar' );
    unregister_sidebar( 'secondary-sidebar' );
}
add_action( 'admin_init', 'illumini_remove_sidebars' );
 
function illumini_setup() {
    add_filter( 'dkret_attachment_image_size', 'illumini_attachment_size' );
    add_filter( 'dkret_entry_title', 'illumini_entry_title' );
    add_filter( 'dkret_entry_meta_before', 'illumini_entry_meta_before' );
    add_filter( 'dkret_entry_meta', 'illumini_entry_meta' );
    add_filter( 'wp_page_menu_args', 'illumini_navigation' );
}
add_action( 'after_setup_theme', 'illumini_setup' );

// change the page navigation to display 4 levels (if no custom navigation is used)
// the dkret3 theme also uses 4 levels as default - leave as an example how to filter
// wp_page_menu
function illumini_navigation( $args ) {
    $args['depth'] = '4';
    return $args;
}

// filter to change the size of attachments
function illumini_attachment_size() {
    return array( 520, 520 );
}

// change the display of the title for illumini
function illumini_entry_title() {
    return '[entry-title]';
}

// change the display of entry-meta information after the title for illumini
function illumini_entry_meta_before() {
    return '<p class="entry-meta-before">[entry-published]</p>';
}

// change the display of the entry-meta information for illumini
function illumini_entry_meta() {
    return '<p class="entry-meta">[entry-categories after=" | "] [entry-tags after=" | "] [entry-comments after=" | "] [entry-edit-link]</p>';
}
?>